/**
 * 用户组处理模块
 */
(function($ns){
    /**
     * 删除用户组
     */
    $ns.deleteGroup = function(gid) {
	Qadmin.FW.Dialog.confirm({
	    msg: '确定要删除记录？',
	    ok: function() {
		Qadmin.FW.Ajax.get({
		    url: [QG_CONFIG.PATH + "group/delete.htm?gid=", gid].join("")
		}, function(xhr){
		    location.reload();
		});
	    }
	});
    };
    
    /**
     * 更新用户组
     */
    $ns.updateGroup = function(gid) {
        Qadmin.FW.Url.goToUrl(QG_CONFIG.PATH + "group/update.htm?gid="+gid);
    }
    
    /**
     * 获取用户组权限绑定
     */
    $ns.getBindResource = function(gid) {
        Qadmin.FW.Url.goToUrl(QG_CONFIG.PATH + "bind/bindResource.htm?gid="+gid);
    }
    
    /**
     * 获取当前组成员
     */
    $ns.getGroupUsers = function(gid) {
        Qadmin.FW.Url.goToUrl(QG_CONFIG.PATH + "user/listByGid.htm?gid="+gid);
    }
})(using("Qadmin.App.Group"));